package com.day1020;

import javax.imageio.ImageIO;
import java.awt.image.BufferedImage;
import java.io.File;
import java.io.IOException;
import java.net.URL;

public class ImageLoadUtils {
    public static BufferedImage load(String imgName){
        BufferedImage img = null;
        try {
            img = ImageIO.read(new File("src\\main\\java\\com\\day1020\\imgs\\" + imgName));
        } catch (IOException e) {
            e.printStackTrace();
        }
        return img;
    }
}
